<?php

use Illuminate\Routing\Router;
use Illuminate\Support\Facades\Route;
use Dcat\Admin\Admin;

Admin::routes();

Route::group([
    'prefix'        => config('admin.route.prefix'),
    'namespace'     => config('admin.route.namespace'),
    'middleware'    => config('admin.route.middleware'),
], function (Router $router) {

    $router->get('/', 'HomeController@index');
    $router->resource('/org/mng', 'OrgDepartmentController');
    $router->resource('/org/team', 'OrgTeamController');
    $router->resource('/team/user', 'TeamMemberController');
    $router->resource('/task/mng', 'MemberTaskController');
    $router->resource('/task/todo', 'TodoTaskController');
    $router->put("/dcat-api/render/{id}", 'MemberTaskController@update')->where('id', '[0-9]+');
    $router->resource('/task/member', 'TaskMemberController');
    $router->get('/api/team', 'TeamMemberController@api');
    $router->get('/api/member', 'MemberTaskController@api');
});
